home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / calendar / frmmain.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1999-08-27  |  5.9 KB  |  204 lines

  1. VERSION 5.00
  2. Begin VB.Form Main 
  3.    BorderStyle     =   0  'None
  4.    Caption         =   "Microsoft Internet Explorer Sim"
  5.    ClientHeight    =   945
  6.    ClientLeft      =   0
  7.    ClientTop       =   0
  8.    ClientWidth     =   1080
  9.    Icon            =   "frmMain.frx":0000
  10.    LinkTopic       =   "Form1"
  11.    MaxButton       =   0   'False
  12.    Picture         =   "frmMain.frx":030A
  13.    ScaleHeight     =   945
  14.    ScaleWidth      =   1080
  15.    ShowInTaskbar   =   0   'False
  16.    StartUpPosition =   3  'Windows Default
  17.    Begin VB.Timer Timer1 
  18.       Enabled         =   0   'False
  19.       Interval        =   2000
  20.       Left            =   5325
  21.       Top             =   690
  22.    End
  23.    Begin VB.Label Label4 
  24.       Alignment       =   2  'Center
  25.       BackColor       =   &H00000000&
  26.       Caption         =   "Help"
  27.       BeginProperty Font 
  28.          Name            =   "Arial"
  29.          Size            =   8.25
  30.          Charset         =   0
  31.          Weight          =   700
  32.          Underline       =   0   'False
  33.          Italic          =   0   'False
  34.          Strikethrough   =   0   'False
  35.       EndProperty
  36.       ForeColor       =   &H00FFFFFF&
  37.       Height          =   195
  38.       Left            =   45
  39.       TabIndex        =   3
  40.       Top             =   705
  41.       Width           =   990
  42.    End
  43.    Begin VB.Label Label5 
  44.       BackStyle       =   0  'Transparent
  45.       Height          =   360
  46.       Left            =   0
  47.       TabIndex        =   2
  48.       Top             =   0
  49.       Width           =   1075
  50.    End
  51.    Begin VB.Label Label3 
  52.       Alignment       =   2  'Center
  53.       BackColor       =   &H00000000&
  54.       Caption         =   "Start"
  55.       BeginProperty Font 
  56.          Name            =   "Arial"
  57.          Size            =   8.25
  58.          Charset         =   0
  59.          Weight          =   700
  60.          Underline       =   0   'False
  61.          Italic          =   0   'False
  62.          Strikethrough   =   0   'False
  63.       EndProperty
  64.       ForeColor       =   &H00FFFFFF&
  65.       Height          =   195
  66.       Left            =   45
  67.       TabIndex        =   1
  68.       Top             =   420
  69.       Width           =   990
  70.    End
  71.    Begin VB.Image Image6 
  72.       Height          =   285
  73.       Left            =   0
  74.       Picture         =   "frmMain.frx":400C
  75.       Top             =   660
  76.       Width           =   1080
  77.    End
  78.    Begin VB.Image Image1 
  79.       Height          =   285
  80.       Left            =   0
  81.       Picture         =   "frmMain.frx":5968
  82.       Top             =   375
  83.       Width           =   1080
  84.    End
  85.    Begin VB.Label Label2 
  86.       Alignment       =   2  'Center
  87.       BackColor       =   &H00000000&
  88.       BackStyle       =   0  'Transparent
  89.       Caption         =   "IE5 Sim"
  90.       BeginProperty Font 
  91.          Name            =   "MS Sans Serif"
  92.          Size            =   8.25
  93.          Charset         =   0
  94.          Weight          =   700
  95.          Underline       =   0   'False
  96.          Italic          =   0   'False
  97.          Strikethrough   =   0   'False
  98.       EndProperty
  99.       ForeColor       =   &H00FFFFFF&
  100.       Height          =   180
  101.       Left            =   180
  102.       TabIndex        =   0
  103.       Top             =   90
  104.       Width           =   720
  105.    End
  106.    Begin VB.Image Image4 
  107.       Height          =   285
  108.       Left            =   0
  109.       Picture         =   "frmMain.frx":72C4
  110.       Top             =   1275
  111.       Width           =   1080
  112.    End
  113.    Begin VB.Image Image5 
  114.       Height          =   285
  115.       Left            =   0
  116.       Picture         =   "frmMain.frx":8C20
  117.       Top             =   1275
  118.       Width           =   1080
  119.    End
  120. Attribute VB_Name = "Main"
  121. Attribute VB_GlobalNameSpace = False
  122. Attribute VB_Creatable = False
  123. Attribute VB_PredeclaredId = True
  124. Attribute VB_Exposed = False
  125. Dim c
  126. Private Sub Form_Load()
  127. c = 1
  128. End Sub
  129. Private Sub Form_Unload(Cancel As Integer)
  130. End Sub
  131. Private Sub Image1_Click()
  132. If Label3.Caption = "Start" Then
  133. Label3.Caption = "Stop"
  134. Timer1.Enabled = True
  135. ElseIf Label3.Caption = "Stop" Then
  136. Label3.Caption = "Start"
  137. Timer1.Enabled = False
  138. End If
  139. End Sub
  140. Private Sub Image1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  141. Image1 = Image5
  142. End Sub
  143. Private Sub Image1_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
  144. Image1 = Image4
  145. End Sub
  146. Private Sub Image6_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  147. Image6 = Image5
  148. End Sub
  149. Private Sub Image6_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
  150. Image6 = Image4
  151. End Sub
  152. Private Sub Label3_Click()
  153. If Label3.Caption = "Start" Then
  154. Label3.Caption = "Stop"
  155. Timer1.Enabled = True
  156. ElseIf Label3.Caption = "Stop" Then
  157. Label3.Caption = "Start"
  158. Timer1.Enabled = False
  159. End If
  160. End Sub
  161. Private Sub Label3_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  162. Image1 = Image5
  163. End Sub
  164. Private Sub Label3_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
  165. Image1 = Image4
  166. End Sub
  167. Private Sub Label4_Click()
  168. help.Show
  169. End Sub
  170. Private Sub Label4_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  171. Image6 = Image5
  172. End Sub
  173. Private Sub Label4_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
  174. Image6 = Image4
  175. End Sub
  176. Private Sub Label5_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  177. If Button = 1 Then
  178. ReleaseCapture
  179. Call SendMessage(main.hwnd, WM_NCLBUTTONDOWN, 2, 0&)
  180. ElseIf Button = 2 Then
  181. End If
  182. End Sub
  183. Private Sub Timer1_Timer()
  184. If c = 1 Then
  185. c = True
  186. End If
  187. Call SetForegroundWindow(main.hwnd)
  188. Dim RECT As POINTAPI, a&, b&
  189. Call GetCursorPos(RECT)
  190. a& = RECT.X
  191. b& = RECT.Y
  192. If c = True Then
  193. Call SetCursorPos(a& + 1, b)
  194. ElseIf c = False Then
  195. Call SetCursorPos(a& - 1, b)
  196. End If
  197. If a& = Screen.Width / Screen.TwipsPerPixelX - 1 Then
  198. c = False
  199. End If
  200. If a& = 0 Then
  201. c = True
  202. End If
  203. End Sub
  204.